#ifndef _DRAWABLE_OBJECT
#define _DRAWABLE_OBJECT

#include <windows.h>
#include <d3d10.h>
#include <d3dx10.h>
#include "iDrawable.h"
#include "vertex.h"

class DrawableObject : public IDrawable
{
private:
	ID3D10Device * m_pd3dDevice;
	ID3D10Buffer * m_pVertexBuffer;
	ID3D10Buffer * m_pIndexBuffer;
	D3D10_PRIMITIVE_TOPOLOGY m_Topology;
	
	D3DXVECTOR3 m_Position;
	
	int m_vertexBufferSize;
	int m_indexBufferSize;


public:
	DrawableObject(ID3D10Device * device);
    void Draw();
	void CreateVertexBuffer(SimpleVertex * vertices, int n);
	void CreateIndexBuffer(DWORD * vertices, int n, D3D10_PRIMITIVE_TOPOLOGY topology=D3D10_PRIMITIVE_TOPOLOGY_TRIANGLELIST);
	~DrawableObject();

};





#endif
